#pragma once
#include <iostream>
#include <string>
#include <json/json.h>

enum ServerType
{
	CreateRoom = 0,
	StartGame,
	DestoryRoom,


	JoinRoom,
	QuitRoom,
	Ready,
	CancelReady,


	PlayGame,

	PlayerMove,
	SwordMove,

	BlockCollision,
	PlayerCollision,
	SwordCollision,
	EdgeCollision,
};

class Request
{
public:
	Request(){}

	virtual bool Serialize(std::string* msg) = 0;
	virtual bool Deserialize(const std::string& result) = 0;


	virtual ~Request(){}
private:
};

class Response
{
public:
	Response()  {}

	virtual bool Serialize(std::string* msg) = 0;
	virtual bool Deserialize(const std::string& result) = 0;

	virtual ~Response() {}
private:
};